import java.net.URI;

import goodmemo.client.MemoClient;
import goodmemo.server.MemoEntry;
import goodmemo.server.MemoEntries;
import java.util.List;
import java.util.ArrayList;



import java.util.Calendar;


public class TestMain{
    public static void main(String[] args) throws Exception {

        MemoClient mclient = new MemoClient();

        ArrayList<Long> a = new ArrayList<Long>();
        a.add(new Long(821084388311L));
        a.add(new Long(821088881111L));

        Calendar calendar = Calendar.getInstance();
        long mtime = calendar.getTime().getTime();
        System.out.println(mtime);
        MemoEntry p = new MemoEntry(1,821071846689L,a,"test");
        System.out.println(p);
        boolean r=mclient.uploadMemo("http://localhost:8080/goodmemo/uploadmemo/",p);
        System.out.println(r);
        MemoEntries mes = 
            mclient.downloadMemo("http://localhost:8080/goodmemo/getmemo/821084388311");
        System.out.println(mes);
        for (MemoEntry me : mes.getMemoEntries()) 
            System.out.println(me);
    }
}
